//
//  PdfTopHomeView.m
//  PdfChange
//
//  Created by 蓝鳍互娱 on 2024/7/25.
//

#import "PdfTopHomeView.h"

@implementation PdfTopHomeView
-(instancetype)init{
    if (self == [super init]) {
        [self creatPdfSubView];
    }
    return self;
}
- (void)creatPdfSubView{
    UIImageView * pdfTopImgView = [[UIImageView alloc] init];
    pdfTopImgView.image = PdfImageNamed(@"pdfHomeTopIcon");
    [self addSubview:pdfTopImgView];
    [pdfTopImgView mas_makeConstraints:^(MASConstraintMaker *make) {
        make.left.equalTo(@(PdfRatio(25)));
        make.bottom.equalTo(@(-PdfRatio(40)));
        make.width.equalTo(@(PdfRatio(88)));
        make.height.equalTo(@(PdfRatio(88)));
    }];
    UIImageView * pdfTopAlertWorldImgView = [[UIImageView alloc] init];
    pdfTopAlertWorldImgView.image = PdfImageNamed(@"pdfHomeTopAlertWorldIcon");
    [self addSubview:pdfTopAlertWorldImgView];
    [pdfTopAlertWorldImgView mas_makeConstraints:^(MASConstraintMaker *make) {
        make.left.equalTo(pdfTopImgView.mas_right).offset(PdfRatio(14));
        make.bottom.equalTo(@(-PdfRatio(43)));
        make.width.equalTo(@(PdfRatio(265)));
        make.height.equalTo(@(PdfRatio(24)));
    }];
    UIImageView * pdfTopWorldImgView = [[UIImageView alloc] init];
    pdfTopWorldImgView.image = PdfImageNamed(@"pdfHomeTopWorld");
    [self addSubview:pdfTopWorldImgView];
    [pdfTopWorldImgView mas_makeConstraints:^(MASConstraintMaker *make) {
        make.left.equalTo(pdfTopImgView.mas_right).offset(PdfRatio(14));
        make.bottom.equalTo(pdfTopAlertWorldImgView.mas_top).offset(-PdfRatio(11));
        make.width.equalTo(@(PdfRatio(210)));
        make.height.equalTo(@(PdfRatio(41)));
    }];
   
}
@end
